package servlets;

import java.io.IOException;
import javax.servlet.RequestDispatcher;
import javax.servlet.ServletException;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

/**
 * 
 * @author andrei costache
 *
 */
public class ContentListViewController extends ContentController {

	@Override
	public void doRequest(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {
            RequestDispatcher view = null;
            request.setAttribute("contentList", contentDAO.findAll());
            view = request.getRequestDispatcher("/jsp/ContentListView.jsp");
            view.forward(request, response);
	}
}
